<template>
  <a-popconfirm v-if="record.status == 4" title="确定放款吗" @confirm="() => submit()">
    <a href="javascript:;">确认放款</a>
  </a-popconfirm>
  <span v-else>已放款</span>
</template>
<script>
import { reviseWithdraw } from '@/api/common'
export default {
  name: 'withdrawStatus',
  components: {},
  props: ['record'],
  data() {
    return {}
  },
  watch: {},
  computed: {},
  methods: {
    async submit() {
      await reviseWithdraw(this.record.id, { status: 2 })
      this.$emit('update')
    }
  },
  created() {},
  mounted() {}
}
</script>
<style lang="css" scoped></style>
